package models.messages;

public class Info {

	final GameStatus gameStatus;
	
	public Info( GameStatus gameStatus){
		this.gameStatus = gameStatus;
	}
	
	public GameStatus getGameStatus(){
		return this.gameStatus;
	}
	
	public String messagePlayerJoined(String playerName){
		
		String result = "[Info] " + playerName + " has hoined.";
		
		return result;
	}
	
	public String messagePlayerLeft(String playerName){
		
		String result = "[Info] " + playerName + " ahs left.";
		
		return result;
	}
	
	public String messagePlayerInAction(){
		
		String result = "[Info] " + this.gameStatus.playerNames[this.gameStatus.playerInAction] + " makes action.";
		
		return result;
	}
	
	public String messagePlayerMadeAction(String playerName, String action, int raise){
		
		String result = "[Info] " + playerName + " made action: " + action + ".";
		
		if( raise > 0 ){
			result += " Bet raised by: " + raise + ". Current bet: " + this.gameStatus.betAmount + "."; 
		}
		
		return result;
	}
	
	public String messagePlayerExchangedCards(String playerName, int amount){
		
		String result = "[Info] " + playerName + " exchanged " + amount + " cards.";
		
		return result;
	}
	
	public String messageGameStarts(String dealerName){
		
		String result = "[Info] Game started. " + dealerName + "is dealing.";
		
		return result;
	}
	
	public String messageNewBettingRound(){
		
		String result = "[Info] Betting round " + this.gameStatus.bettingRound + "started.";
		
		return result;
	}
	
	public String messageGameStarts(){
		
		String result = "[Info] Game started.";
		
		return result;
	}
	
	
}
